1. Field of the Invention
The present invention generally relates to data processing systems and computer-readable recording media recorded with a program for causing a computer to process data such that data is stored in files, and more particularly to a data processing system and a computer-readable recording medium recorded with a program for causing a computer to process data, which is obtained by predetermined steps including sorting and merging steps, so that the data is divided and stored into a plurality of files.
2. Description of the Related Art
Conventionally, in a case of storing a large volume of data in files, a data processing system is provided such that a plurality of physical files are assigned to one logical file in accordance with volume of data (the number of additional records) to store. For example, a detailed description of the data processing system is found in Japanese Laid-open Patent Application No.4-287140.
In this conventional data processing system, a user stores one logical file having a relatively large volume of data into a plurality of physical files without management thereof.
Also, there is another conventional data processing system which can store following data into a next file indicated by a user when a volume of stored data in a current file reaches the maximum capacity for the current file defined by a file system or when a disk does not have enough storage space to store more data. Thus, it is possible to complete storage of an entire large volume of data by indicating the next file even if the current file in the process of storing data can not complete storage of the entire large volume of data.
In such conventional systems mentioned above, the systems define the size (maximum space available) of each file to store divided data. However, the systems do not allow a user to arrange the size of each file that is used to store divided data. Accordingly, it is not possible for the user to define a plurality of output files beforehand at once and arrange beforehand the size thereof in accordance with storage media that are to store the large volume of data.
Moreover, in the conventional systems in which data from a database is stored in a plurality of output files by dividing, it is not taken in consideration that a large volume of data could be sorted by predetermined categories and divided based on the categories to create secondary databases. Accordingly, in this case, in order to make desired secondary databases, the user has to retrieve desired data from the large volume of data for each output file and save the desired data in a corresponding output file as one of the secondary databases.
It is a general object of the present invention to provide a data processing system in which the above-mentioned problems are eliminated.
A more specific object of the present invention is to provide a data processing system that allows a user to provide information about output files and the size of each output file and that divides data and outputs divided data into the output files in accordance with the information provided by the user.
Another object of the present invention is to provide a computer readable-recording medium recorded with a program for causing a computer to process data, which is obtained by predetermined steps including sorting and merging steps, so that the data is divided and stored in a plurality of output files.
The above objects of the present invention are achieved by a data processing system for processing a set of data, the data processing system including: a maximum capacity setting part setting a maximum capacity of data corresponding to each of a plurality of output files in accordance with information from an external unit; a judging part judging whether a total volume of data stored in a current output file, which is one of the plurality of output files, reaches the maximum capacity corresponding to the current output file when data is processed and stored in the current output file; and an output file switching part switching the current output file to another of the plurality of output files when it is judged that the total volume of data stored in the current output file reaches the maximum capacity corresponding to the current output file, whereby the set of data is divided and stored in the plurality of output files.
According to the present invention, the maximum capacity is set for each of the plurality of output files. Then, the data is processed and stored into a current output file. When the total volume of data stored in the current output file reaches the maximum capacity, the data processing system switches the current output file to another of the plurality of output files. Therefore, it is possible to divide the set of data in accordance with the maximum capacity of each of the plurality of output files and to store the set of data therein by switching the plurality of output files in sequence.
Moreover, the above objects of the present invention are achieved by a computer-readable recording medium recorded with a program for causing a computer to process a set of data, the program including the codes of: (a) setting a maximum capacity of data corresponding to each of a plurality of output files in accordance with information from an external unit; (b) judging whether a total volume of data stored in a current output file, which is one of the plurality of output files, reaches the maximum capacity corresponding to the current output file when data is processed and stored in the current output file; and (c) switching the current output file to another of the plurality of output files when it is judged that the total volume of data stored in the current output file reaches the maximum capacity corresponding to the current output file, whereby the set of data is divided and stored in the plurality of output files.
According to the present invention, a computer-readable recording medium recorded with a program for causing a computer to process a set of data is provided to divide the set of data in accordance with the maximum capacity of each of the plurality of output files and to store the data therein by switching the plurality of output files in sequence.